85c6203d2bb9f331bfa299e67607ab57192042c7,src/com/hotmail/kalebmarc/textfighter/main/Shop.java,Shop,xp,#,180

Before Change



            //Makes sure player isn't level 10 already
            if (Xp.getLevel() == 100) {
                Ui.cls();
                Ui.println("You're already level 100! You cannot buy any more xp.");
                Ui.pause();
                return;
            }

            Ui.cls();
            Ui.println("-------------------------------------------------------------------");
            Ui.println("                                 XP                                ");
            Ui.println();
            NPC.welcome("XP");
            Ui.println();
            Ui.println("Level: " + Xp.getLevel());
            Ui.println("XP: " + Xp.getFull());
            Ui.println("Coins: " + Coins.get());
            Ui.println();
            Ui.println("You can buy XP for 1 coin per XP. How much would you like to buy?");
            Ui.println("**Enter 0 to go back**");
            Ui.println("-------------------------------------------------------------------");

            int buy = Ui.getValidInt();
            valid = true;

            //Tests
            if (buy > Coins.get()) {
                //Not enough coins
                Ui.cls();
                Ui.println("You don't have enough coins to buy this much xp.");
                valid = false;
                Ui.pause();
            }
            if (Xp.getLevel() == 100) {
                Ui.cls();
                Ui.println("You are already level 100; which is the maximum level.");
                valid = false;
                Ui.pause();
            }
            if (buy < 0) {
                Ui.cls();
                Ui.println("You can't buy a negative amount of Xp.. Nice try though ;)");
                valid = false;
                Ui.pause();
            }
            if (buy == 0) {
                return;
            }

            if (valid) {
                Ui.cls();
                Ui.println("You have bought " + buy + " xp.");
                Ui.pause();

                //Results
                Xp.set(buy, true);

After Change


                valid = false;
            }
            if (Xp.getLevel() == 100) {
                Ui.msg("You are already level 100; which is the maximum level.");
                valid = false;
            }
            if (buy < 0) {
                Ui.msg("You can't buy a negative amount of Xp.. Nice try though ;)");
                valid = false;
            }
            if (buy == 0) {